package com.ytz.controller;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.print.DocFlavor;
import java.util.concurrent.TimeUnit;

@RestController
public class FlowLimitController {

@GetMapping("testA")
public String testA(){
    return  "testA";
}
@GetMapping("testB")
    public String testB(){
    return "testB";
}

@GetMapping("testC")
    public String testC(int id){
if (id==1){
    try {
        TimeUnit.SECONDS.sleep(1);
    } catch (InterruptedException e) {
        e.printStackTrace();
    }
}
return  "testC";
}

}
